{if $smarty.get.clang}
	{ext->class_function class="clients" func="get_pass_letter_data" lang=$smarty.get.clang assign="letter_data"}
{else}
	{ext->class_function class="clients" func="get_pass_letter_data" lang=0 assign="letter_data"}
{/if}
<table width="100%" cellpadding="0" cellspacing="0" style="border:1px solid #C4CDD2; border-top:0px; background:#DBE1E5; padding:0px 5px 5px 5px">
	<tr>
		<td>
		<table width="100%" cellpadding="0" cellspacing="0">
			<tr>
				<td height="10"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>		
			</tr>
			<tr>
				<td height="1" bgcolor="#ADB9BF"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
			</tr>
			<tr>
				<td height="1" bgcolor="#E4E9EC"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
			</tr>
			<tr>
				<td height="10"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>		
			</tr>
		</table>
		
		<table width="100%" cellpadding="0" cellspacing="0" style="border:1px solid silver; background-color:#fefefe">
			<tr>
				<td>
				<table cellpadding="0" cellspacing="0">
					<tr>
						<td height="25" style="padding:0px 10px 0px 10px;">{t t='Pasirinkite kalbą'}:</td>
						<td width="15"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
						<td style="padding:0px 10px 0px 0px;">
							<select name="languages" style="width:70px" onChange="window.location='index.php?admin=1&tpl_client_module=show_pass'+this.value">
							  {foreach from=$data.tree.lang item="el"}
							  <option value="&clang={$el.name}" {if $smarty.get.clang|lower==$el.name|lower}selected{/if}>{$el.name}</option>
							  {/foreach}
							</select>
						</td>
					</tr>
				</table>
				</td>		
			</tr>
		</table>
			
		<table width="100%" cellpadding="0" cellspacing="0">
			<tr>
				<td height="10"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>		
			</tr>
			<tr>
				<td height="1" bgcolor="#ADB9BF"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
			</tr>
			<tr>
				<td height="1" bgcolor="#E4E9EC"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
			</tr>
			<tr>
				<td height="10"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>		
			</tr>
		</table>	
		<table width="100%" cellpadding="0" cellspacing="0" style="border:1px solid #C4CDD2; border-top:0px;">
			<tr>
				<td width="1" bgcolor="#DBE1E5"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
				<td style="border:5px solid white; border-bottom:0px">
					<table width="100%" cellpadding="0" cellspacing="0">
					<tr>
						<td style="border:1px solid #8CA2B1; " bgcolor="#FFFFFF">
							<table width="100%" cellpadding="0" cellspacing="0">
								<tr>
									<td style="line-height:150%">											
									<form action="index.php" method="post" name="form{$data.page.id}" enctype="multipart/form-data">
									<input name="admin" type="hidden" value="1">
									<input name="mod" type="hidden" value="pass_letter">
									<input name="act" type="hidden" value="pass_letter">
									<input name="module" type="hidden" value="clients">
									<input name="referer" type="hidden" value="{ext->get_referer}">
									{if $smarty.get.clang}
										<input name="clang" type="hidden" value="{$smarty.get.clang}">
									{/if}
										<table width="100%" cellpadding="0" cellspacing="0">
											<tr>
												<td height="1" bgcolor="#DBE1E5"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
											</tr>
										</table>
										<table width="100%" cellpadding="0" cellspacing="0" bgcolor="#F8F9F9">	
											<tr>
												<td width="15"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
												<td width="25%" height="25" class="defaultFormLabel" align="right">{t t='letters_subject'}</td>
												<td width="15"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
												<td>
													<input type="text" name="letters_subject" value="{$letter_data.letter_subject|escape:"html"}"  class="defaultInputText">						
												</td>		
											</tr>
										</table>
										<table width="100%" cellpadding="0" cellspacing="0">
											<tr>
												<td height="1" bgcolor="#DBE1E5"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
											</tr>
										</table>
										<table width="100%" cellpadding="0" cellspacing="0" bgcolor="#F8F9F9">	
											<tr>
												<td width="15"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
												<td width="25%" height="25" class="defaultFormLabel" align="right">{t t='letters_from'}</td>
												<td width="15"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
												<td>
													<input type="text" name="letters_from" value="{$letter_data.letter_from|escape:"html"}"  class="defaultInputText">						
												</td>		
											</tr>
										</table>
										<table width="100%" cellpadding="0" cellspacing="0">
											<tr>
												<td height="1" bgcolor="#DBE1E5"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
											</tr>
										</table>
										<table width="100%" cellpadding="0" cellspacing="0" bgcolor="#F8F9F9">
											<tr>
												<td width="15"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
												<td height="25" class="defaultFormLabel">{t t='letters_pass_retrive_before'}</td>		
											</tr>
										</table>
										<table cellpadding="0" cellspacing="0" width="100%"  bgcolor="#F8F9F9">
											<tr>
												<td width="15"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
												<td><textarea name="letters_text_before" class="defaultInputTextarea">{$letter_data.letter_text_before|escape:"html"}</textarea></td>
												<td width="15"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
											</tr>
										</table>
										
										<table width="100%" cellpadding="0" cellspacing="0" bgcolor="#F8F9F9">
											<tr>
												<td width="15"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
												<td height="25" class="defaultFormLabel">{t t='letters_pass_retrive_after'}</td>		
											</tr>
										</table>
										<table cellpadding="0" cellspacing="0" width="100%"  bgcolor="#F8F9F9">
											<tr>
												<td width="15"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
												<td><textarea name="letters_text_after" class="defaultInputTextarea">{$letter_data.letter_text_after|escape:"html"}</textarea></td>
												<td width="15"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
											</tr>
										</table>
										<table width="100%" cellpadding="0" cellspacing="0"  bgcolor="#F8F9F9">
											<tr>
												<td height="15"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>		
											</tr>
										</table>
										<table width="100%" cellpadding="0" cellspacing="0">
											<tr>
												<td bgcolor="#FFFFFF" height="5">						
												</td>		
											</tr>
										</table>
										<table cellpadding="0" cellspacing="0" width="100%">
											<tr>
												<td bgcolor="#FFFFFF" height="5" width="150">						
												<input onClick="doSubmit('form{$data.page.id}'); return false;" type="button" value="{t t="Išsaugoti pakeitimus"}" class="defaultFormButton" style="margin:10px ">
												</td>		
												<td bgcolor="#FFFFFF" height="5"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>		
											</tr>
										</table>
									</form>									
									</td>		
								</tr>
								<tr><td bgcolor="#FFFFFF" height="5"><img src="client/img/spacer.gif" class="spacer" alt="" /></td></tr>
							</table>
						</td>		
					</tr>
					<tr>
						<td bgcolor="#FFFFFF" height="5"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
					</tr>
					</table>
				</td>	
				<td width="1" bgcolor="#DBE1E5"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
			</tr>
		</table>
		</td>		
	</tr>	
</table>
<table width="100%" cellpadding="0" cellspacing="0">
	<tr>
		<td height="1" bgcolor="#DBE1E5"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>
	</tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0">
	<tr>
		<td height="20"><img src="client/img/spacer.gif" class="spacer" alt="" /></td>		
	</tr>
</table>

